package com.xgz.service.instant;

import com.xgz.bean.Cat;
import com.xgz.bean.Person;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Primary;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;

/**
 * 实例化 测试
 * 到底用哪一个构造函数
 * @author xgz
**/
@Component
public class Instantiation {

	private Person person;
	private Cat cat;

	@Autowired
	public Instantiation(Person person, Cat cat) {

		this.person = person;
		this.cat = cat;
	}

	public Instantiation(Person person) {
		this.person = person;
	}

	public Instantiation(Cat cat) {
		this.cat = cat;
	}

	public Instantiation() {
	}



	public Person getPerson() {
		return person;
	}

	public void setPerson(Person person) {
		this.person = person;
	}

	public Cat getCat() {
		return cat;
	}

	public void setCat(Cat cat) {
		this.cat = cat;
	}
}
